//
//  CacheManger.m
//  FNMenu
//
//  Created by 航汇聚科技 on 2018/9/29.
//  Copyright © 2018年 Yi Zhou. All rights reserved.
//

#import "CacheManger.h"

@interface CacheManger ()
@property (nonatomic, strong) NSCache *cache;
@end

@implementation CacheManger

#pragma mark - lifeCycle
+ (instancetype)sharedCacheManager {
    static CacheManger *manager = nil;
    static dispatch_once_t onceToken;
    dispatch_once(&onceToken, ^{
        manager = [[CacheManger alloc] init];
    });
    return manager;
}

#pragma mark - getter
- (NSCache *)cache {
    if (!_cache) {
        _cache = [[NSCache alloc] init];
    }
    return _cache;
}
@end
